<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>我的部门信息</title>
    <link rel="stylesheet" href="/vendor/simple-line-icons/css/simple-line-icons.css">
    <link rel="stylesheet" href="/vendor/font-awesome/css/fontawesome-all.min.css">
    <link rel="stylesheet" href="/css/styles.css">
</head>
<body>
<div class="page-wrapper">
<div class="main-container">
<div class="content">
    <div class="container">
        <div class="row">
            <div class="col-12">
                <div class="card">
                    <div class="card-body p-0">

                        <div class="row pb-5 p-5">
                            <div class="col-md-6">
                                <p class="font-weight-bold mb-4">我的部门信息</p>
                                <p class="mb-1" id="departmentName">部门名称：</p>
                            </div>

                            <div class="col-md-6 text-right">
                                <p class="font-weight-bold mb-4">详情</p>
                                <p class="mb-1" id="departmentId"><span class="text-muted">部门编码: </span></p>
                                <p class="mb-1" id="departmentKpi"><span class="text-muted">部门考评总分: </span></p>
                            </div>
                        </div>

                       <!-- <div class="row p-5">
                            <div class="col-md-12">
                                <a href="/employee/department_list"><button type="button" class="btn btn-outline-primary">所有部门</button></a>
                            </div>
                        </div>-->

                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
</div>
</div>
<script src="/vendor/jquery/jquery.min.js"></script>
<script src="/vendor/popper.js/popper.min.js"></script>
<script src="/vendor/bootstrap/js/bootstrap.min.js"></script>
<script src="/vendor/chart.js/chart.min.js"></script>
<script>
    $(document).ready(function () {
        $.ajax({
            url : "/employee/getUserDepartment",     //后台请求的数据
            dataType : "json",              //数据格式 
            type : "post",                  //请求方式
            async : true,                   //是否异步请求
            success : function(data) {      //如果请求成功，返回数据。
                $("#departmentName").append(data.departmentName);
                $("#qdkh").append(data.qdkh);
                $("#qdms").append(data.qdms);
                $("#departmentId").append(data.departmentId);
                $("#departmentKpi").append(data.departmentKpi);
            },
        });

    });
</script>
</body>
</html>
